{template 'header'}
<link rel="stylesheet" href="{CSS_URL}store.css"/>
<!--当前位置-->
<div class="location layout960">
	<!--{template 'location', MODULE_NAME}-->
</div>
<!--当前位置 end-->
<!--主体部分-->
<div class="cooper-hd layout960 fn-clear">
	<h2 class="fn-left">车企在线店</h2>
	<a class="join" href="{url('store/join')}">在线店加盟</a>
	<p class="loc fn-left">
<a href="{url('store/index')}" title="查看本地">查看本地</a>
	</p>
</div>
<div class="cooper-main layout960">
	<!--筛选 start-->
	<div class="cooper-filter">
		<div class="filter-block fn-clear bd-bot">
			<div class="filter-cat fn-left">
				<h4 class="c666">商家分类</h4>
				<i></i>
			</div>
			<div class="filter-list fn-left">
				<!--{php $catCatsLevel = 0}-->
				<!--{loop $maincat $k1 $mainL}-->
				<ul class="fn-clear ">
					<!--{if !$catCatsLevel}-->
					<li {if !$catid}class="selected"{/if}>
					<a  href="{url('store/list', array('catid'=>0, 'areaid'=>$areaid, 'bid'=>$bid))}" title="不限">不限</a>
					</li>
					<!--{/if}-->
					<!--{php $catCatsLevel++}-->
					<!--{loop $mainL $k2 $v}-->
					{if $v['catid'] != 18}
					<li {if $v[catid]==$catid} class='selected'{/if}>
					<a  href="{url('store/list', array('catid'=>$v['catid'], 'areaid'=>$areaid, 'bid'=>$bid))}" title="{$v[catname]}">{$v[catname]}</a></li>
					{/if}
					<!--{/loop}-->
				</ul>
				<!--{/loop}-->

			</div>
			<select class="fn-right sel-brand" >
				<option data-url="{url('store/list', array('catid'=>$catid, 'areaid'=>$areaid))}">选择适用车型</option>
				{loop $brands $k $t}
				{if $k!=''}
				<optgroup label="{$k}" ></optgroup>
				{loop $t $v}
				<option  data-url="{url('store/list', array('catid'=>$catid, 'areaid'=>$areaid, 'bid'=>$v['arid']))}"  {if $v[arid]==$bid} selected='selected'{/if} >{$k}.{$v[name]}</span></option>
				{/loop}
				{/if}
				{/loop}
			</select >
		</div>
		<div class="filter-block fn-clear bd-bot">
			<div class="filter-cat fn-left">
				<h4 class="c666">地区筛选</h4>
				<i></i>
			</div>
			<div class="filter-list fn-left">
				<ul class="fn-clear">
					<li {if !$areaid}class='selected'{/if}>
					<a href="{url('store/list', array('areaid'=>0, 'catid'=>$catid, 'bid'=>$bid))}" title="不限">不限</a>
					</li>
					<!--{loop $areaFilter $v}-->
					<li	{if $v[areaid]==$areaid} class='selected'{/if}>
					<a href="{url('store/list', array('areaid'=>$v['areaid'], 'catid'=>$catid, 'bid'=>$bid))}" title="{$v[areaname]}">{$v[areaname]}</a>
					</li>
					<!--{/loop}-->
				</ul>
			</div>
		</div>
	</div>
	<!--{if $catid}-->
	<!--{php $moduleid=40}-->
	<div class="cat-selected fn-clear ">
		<h5 class="fn-left">{if catSelectName}{$catSelectName}{else}信息{/if}分类：</h5>
		<ul class="fn-left">
			<!--{if $catid && $catid != null}-->
			{php $selectedCats = Category::getParentsAndSelf($catid, $moduleid)}
			{loop $selectedCats $_cat}
			<li><a href="{reUrl($filter, array('catid','ctp','mid','sid'), array($_cat['parentid']))}">{$_cat['catname']}<i class="icon-close"></i></a></li>
			{/loop}
			<!--{/if}-->
		</ul>
	</div>
	<!--{/if}-->
	<!--{if $areaid}-->
	<!--{template 'sel_area', 'filter'}-->
	<!--{/if}-->
	<!--{if $bid}-->
	<div class="cat-selected fn-clear ">
		<h5 class="fn-left">选择品牌：</h5>
		<ul class="fn-left">
			<li><a href="{url('store/list', array('catid'=>$catid, 'areaid'=>$areaid, 'bid'=>0))}">{$brand_tmp[$bid][name]}<i class="icon-close"></i></a></li>
		</ul>
	</div>
	<!--{/if}-->
	<!--筛选 end-->
	<!--汽车服务 start-->
	<div class="cooper-lists">
		<ul class="cooper-list fn-clear">
			<!--{if $lists}-->
			{loop $lists $k $v}
			<li>
				<a class="img" title="title" href="{url('store/show','uid='.$v[userid])}" target="_blank"><img src="{Picture::thumb($v['thumb'], 215, 150)}" ></a>
				<h4 class="text-ellipsis"><a href="{url('store/show','uid='.$v[userid])}" title="{$v[company]}" target="_blank">{$v[company]}</a></h4>
				<p class="intro c666">{$v[business]}</p>
				<p class="owner fn-clear">{Im::web($v[userid])}</p>
			</li>
			{if ($k+1)%4==0}<li class="line"></li>{/if}
			{/loop}
			<!--{else}-->
			<!--{template 'coshop_noinfo', 'message'}-->
			<!--{/if}-->
		</ul>
		<!--{if $total}-->
		{php $pn = $do->getPn()}
		{template 'pager', 'inc'}
		<!--{/if}-->
	</div>
	<!--汽车服务 end-->
</div>
<!--主体部分end-->
<script>
	seajs.use(["$",'common'],function($){
		$('.sel-brand').change(function(){
			window.location = $(this).find('option:selected').attr('data-url')
		})
	});
</script>

{template 'footer'}